package com.base.thread.demo_23;

public class Demo {
 
	MyLock lock = new MyLock();
	
	private void a() {
		lock.lock();
		System.out.println("a");
		b();
		lock.unlock();
	}
	private void b() {
		lock.lock();
		System.out.println("b");
		lock.unlock();
	}
	
	public static void main(String[] args) {
		Demo demo = new Demo();
		demo.a();
	}
}
